<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <style>
    /* 鼠标悬停时被选中 */

    div:hover {
      color: yellow;
    }

    /* div:first-child {
      color: red;
    } */

    div:first-of-type {
      color: red;
    }

    div:nth-child(2n+1) {
      color: red;
    }

    /* 伪元素&伪对象 */

    /* 审查元素： 打开控制台【开发者工具】（f12） */
    /* #div5::after {
      content: "";
    } */

    #div5::before {
      content: "999";
    }
  </style>

</head>

<body>
  p也算一个元素
  <p>23456</p>
  <div>div1</div>
  <div>div2</div>
  <div>div3</div>
  <div>div4</div>
  <div id="div5">
    div5
  </div>
</body>

</html>